<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<script src="script/jquery-1.10.min.js">
// <script src="https://cdn.bootcss.com/jquery/1.10.2/jquery.min.js"></script>
<!-- <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css"> -->
<link rel="stylesheet" href="script/bootstrap-3.3.7.min.css">
<script src="script/jquery-1.10.min.js"></script>
<script src="script/bootstrap-3.3.7.min.js"></script>


<script>
$(document).ready(function(){
    var data = {'a':[20,30],'b':[10,20],'c':[15,30]}
     $("#static_dropdown").change(function(event){
        var progress_data = data[$(this).val()] //提取匹配的数据
        var p = Number(progress_data[0] / progress_data[1]).toFixed(2); //保留两位小数
        $("#progress").css("width",p*100+"%")
     })
});
</script>
</head>
<body>
    <div class="container"> 

        <div class="row">
           
           <div class="col-sm-3 col-md-3">
              <select id="static_dropdown" class="form-control">
                  <option id="a">a</option>
                  <option id="b">b</option>
                  <option id="c">c</option>
              </select>

            </div>
          </div>
       
          <div class="row">
            <div class="col-md-3 col-sm-3">
              
  
                <div class="progress">
                    <div id = "progress" class="progress-bar progress-bar-default" role="progressbar"
                       aria-valuenow="10" aria-valuemin="0" aria-valuemax="100"
                       style="width: 30%;">
                      <span class="sr-only">10% 完成（危险）</span>
                    </div>
                  </div>
              
            </div>
          </div>

      </div>
</body>
</html>
